/* Code licensed under the BSD License: http://www.opensource.org/licenses/bsd-license.php */
/**
* @description <p>Widgets used for PhoneBook2 only.</p>
**/

MENU.editor_div_field = null;

MENU.editorDiv = function (oDialog) {
    if (arguments.length>0) {
        MENU.editor_div_field = oDialog;
    }
    return MENU.editor_div_field;
};

MENU.getEditorDiv = MENU.editorDiv;
MENU.setEditorDiv = MENU.editorDiv;

EDITOR.activate = function () {
    MENU.getEditorDiv().show();
};
        
LISTER.activate = function () {
    MENU.getEditorDiv().hide();
    LISTER.listerActivateEvent.fire(LISTER);
};             

MENU.initEditorDiv = function () {
    var dialog = new YAHOO.widget.Dialog("editorDiv",
        { width:"600px",  
          fixedcenter:true,  
	      visible:false
        }    
    );
    MENU.setEditorDiv(dialog).render();    
}

YAHOO.util.Event.onAvailable("editorDiv",MENU.initEditorDiv); 

